using UnityEngine;
using System.Collections;

public class TweenPos : NGUITweenValue {
	Transform m_MyTransform;
	Transform MyTransform{
		get{
			if(m_MyTransform == null)
				m_MyTransform = gameObject.GetComponent<Transform>();
			return m_MyTransform;
		}
	}
	public Vector3 m_From;
	public Vector3 m_To;
	public bool m_Local = true;
	public override void ValueChange(float f){
		if (m_Local) 
			MyTransform.localPosition = Vector3.Lerp(m_From,m_To,f);
		else
			MyTransform.position = Vector3.Lerp(m_From,m_To,f);

	}
}
